import Mock from 'mockjs';
import { AjaxResponseWrapper, APP_TOKEN } from '~/common';
import { SUCCESS_CODE } from '~/common/request.ts';

Mock.mock('/login', 'post', (): AjaxResponseWrapper<void> => {
  let token = Mock.mock('@guid');
  return {
    code: SUCCESS_CODE,
    extras: {
      [APP_TOKEN]: token
    }
  };
});
